package com.smbms.dao.user.mapper;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;

import com.smbms.pojo.User;

public interface UserMapper {
	//鎺ュ彛鐨勫唴瀹� MAPPER鏂囦欢涓殑鏌ヨ锛屾煡璇㈢殑ID锛�
	//鐩稿綋浜庢帴鍙ｄ腑瀹氫箟鐨勬柟娉曪紝鏂规硶鍚嶅拰鏌ヨ鐨処D涓�鑷达紝杩斿洖绫诲瀷瑕佸拰鏌ヨ 涓�鑷�
	public int count();
	public List<User> searchAll();
	public List<User> 
	searchByNameAndGender(
		@Param("userName")String userName,
		@Param("gender")int gender,
		@Param("role")int role);
	
	public List<User> 
	searchByUser(User user);
	
	public List<User> 
	searchByMap(Map<String, String> map);
	
	public List<User> searchByCondition();
	
	public int add(User user);
	
	public int modify(User user);
	
	public int modifyPassword(
			@Param("psw")String userPassword,
			@Param("name")String userName);
	
	public int delUser(User user);
	
	
}
